package com.example.jetpack.b_viewModel_livedata

import androidx.lifecycle.ViewModel
import androidx.lifecycle.ViewModelProvider

@Suppress("UNCHECKED_CAST")
class CounterViewModelFactory(private val counterReversed: Int) : ViewModelProvider.Factory {
    override fun <T : ViewModel> create(modelClass: Class<T>): T {
        return CounterViewModel(counterReversed) as T
    }
}